{{ define "navlist"}}

{{ if .NavCollapse}}
<body class="layui-layout-body hold-transition skin-blue sidebar-mini sidebar-collapse">
{{else}}
<body class="layui-layout-body hold-transition skin-blue sidebar-mini">
{{end}}
<div class="layui-layout layui-layout-admin">
 <header class="main-header layui-header ">
    <!-- Logo -->
    <a href="/index" class="logo">
        <!-- mini logo for sidebar mini 50x50 pixels -->
        <span class="logo-mini"><b>品</b>茗</span>
        <!-- logo for regular state and mobile devices -->
        <span class="logo-lg"><b>品茗</b>代码生成器</span>
    </a>
    <!-- 头部区域（可配合layui已有的水平导航） -->
    <ul class="layui-nav layui-layout-left">
        <li class="layui-nav-item">
            <a href="#" class="sidebar-toggle" data-toggle="push-menu" role="button">
                <span class="sr-only">隐藏导航栏</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </a>
        </li>
      {{/*  <li class="layui-nav-item"><a href="">商品管理</a></li>
        <li class="layui-nav-item"><a href="">用户</a></li>
        <li class="layui-nav-item">
            <a href="javascript:;">其它系统</a>
            <dl class="layui-nav-child">
                <dd><a href="">邮件管理</a></dd>
                <dd><a href="">消息管理</a></dd>
                <dd><a href="">授权管理</a></dd>
            </dl>
        </li>*/}}
    </ul>
    <ul class="layui-nav layui-layout-right">
        <li class="layui-nav-item">
            <a href="javascript:;">
                <img src="http://t.cn/RCzsdCq" class="layui-nav-img">
                {{.user.Username}}
            </a>
            <dl class="layui-nav-child">
                <dd><a href="/user">基本资料</a></dd>
                <dd><a href="/user/setting">安全设置</a></dd>
            </dl>
        </li>
        <li class="layui-nav-item"><a href="/logout">退出</a></li>
    </ul>
</header>
{{ template "leftnav" . }}
{{end}}